package com.testdemo2;

public class Teacher {
    String name;
    String TeachingSubject;

    public Teacher(String name, String teachingSubject) {
        this.name = name;
        TeachingSubject = teachingSubject;
    }
    public void teaching(){
        System.out.println("老师在教书");
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getTeachingSubject() {
        return TeachingSubject;
    }

    public void setTeachingSubject(String teachingSubject) {
        TeachingSubject = teachingSubject;
    }
}
